﻿/********************************************************************************************************************
* Author:	Christos Polydorou																						*
* Email:	std04237@di.uoa.gr																						*
* Purpose:	This script is used in order to create the stored procedure "usp_user_searchwithid" that returns the 	*
*			username of the user with the specified id.																*
********************************************************************************************************************/

CREATE PROCEDURE [dbo].[usp_user_searchwithid]
	@userid bigint
AS
	DECLARE @username nvarchar(50)

	SELECT users.username
	FROM Users
	WHERE Users.id = @userid

RETURN 0